namespace KPIS.GERP.Models.Migrations
{
    using System;
    using System.Data.Entity.Migrations;
    
    public partial class update0025 : DbMigration
    {
        public override void Up()
        {
            DropForeignKey("dbo.IcmMovementDtl", "MovementId", "dbo.IcmMovement");
            DropIndex("dbo.IcmMovementDtl", new[] { "MovementId" });
            AlterColumn("dbo.IcmMovementDtl", "MovementId", c => c.Int());
            AddForeignKey("dbo.IcmMovementDtl", "MovementId", "dbo.IcmMovement", "MovementId");
            CreateIndex("dbo.IcmMovementDtl", "MovementId");
        }
        
        public override void Down()
        {
            DropIndex("dbo.IcmMovementDtl", new[] { "MovementId" });
            DropForeignKey("dbo.IcmMovementDtl", "MovementId", "dbo.IcmMovement");
            AlterColumn("dbo.IcmMovementDtl", "MovementId", c => c.Int(nullable: false));
            CreateIndex("dbo.IcmMovementDtl", "MovementId");
            AddForeignKey("dbo.IcmMovementDtl", "MovementId", "dbo.IcmMovement", "MovementId", cascadeDelete: true);
        }
    }
}
